package com.tulingxueyuan.sentinelnew.feign;

import feign.Param;
import feign.RequestLine;
import org.springframework.cloud.openfeign.FeignClient;

/**
 * @author :tangweiliang
 * @date : 2023/2/1 21:38
 * 未来的你会感谢现在努力的自己
 */
@FeignClient(name = "product-service",path = "/product")
public interface ProductFeignService {

    //  springmvc注解
    //  @RequestMapping("/{id}") // @RequestMapping 对应feign原生注解 @RequestLine
    // public String get(@PathVariable("id") Integer id); // @PathVariable 对应feign原生注解 @Param
    /**
     * feign原生注解
     */
    @RequestLine("GET {/id}")
    public String get(@Param("id") Integer id);
}
